import config from "@/config"
import http from "@/utils/request"

export default {

	// 人流量分析接口
	people: {
		stat: {
			url: `${config.API_URL}/people/stat.do`,
			name: "门店人流量统计",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
	},
	// 活动
	act: {
		list: {
			url: `${config.API_URL}/act/list.do`,
			name: "列表",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		save: {
			url: `${config.API_URL}/act/save.do`,
			name: "新增/修改",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		delete: {
			url: `${config.API_URL}/act/delete.do`,
			name: "删除",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		info: {
			url: `${config.API_URL}/act/get.do`,
			name: "详细",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		exp: {
			url: `${config.API_URL}/act/exp.do`,
			name: "导出",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
	},
	// cam
	cam: {
		clist: {
			url: `${config.API_URL}/cam/clist.do`,
			name: "通道列表",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		func: {
			url: `${config.API_URL}/cam/func.do`,
			name: "设备配置",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		finish: {
			url: `${config.API_URL}/cam/finish.do`,
			name: "门店撤布防列表",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		deploying: {
			url: `${config.API_URL}/cam/deploying.do`,
			name: "门店撤布防",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		stat: {
			url: `${config.API_URL}/cam/stat.do`,
			name: "设备在线统计",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		heat: {
			url: `${config.API_URL}/cam/heat.do`,
			name: "门店热力分析",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		playback: {
			url: `${config.API_URL}/cam/playback.do`,
			name: "spin",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		spin: {
			url: `${config.API_URL}/cam/spin.do`,
			name: "spin",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		live: {
			url: `${config.API_URL}/cam/live.do`,
			name: "live",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		tree: {
			url: `${config.API_URL}/cam/tree.do`,
			name: "树",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		list: {
			url: `${config.API_URL}/cam/list.do`,
			name: "列表",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		save: {
			url: `${config.API_URL}/cam/save.do`,
			name: "新增/修改",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		delete: {
			url: `${config.API_URL}/cam/delete.do`,
			name: "删除",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		info: {
			url: `${config.API_URL}/cam/get.do`,
			name: "详细",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
	},
	// flow
	flow: {
		list: {
			url: `${config.API_URL}/flow/list.do`,
			name: "列表",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		save: {
			url: `${config.API_URL}/flow/save.do`,
			name: "新增/修改",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		delete: {
			url: `${config.API_URL}/flow/delete.do`,
			name: "删除",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		info: {
			url: `${config.API_URL}/flow/get.do`,
			name: "详细",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
	},
	// level
	level: {
		get: {
			url: `${config.API_URL}/level/get.do`,
			name: "列表",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		list: {
			url: `${config.API_URL}/level/list.do`,
			name: "列表",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		save: {
			url: `${config.API_URL}/level/save.do`,
			name: "新增/修改",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		delete: {
			url: `${config.API_URL}/level/delete.do`,
			name: "删除",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		info: {
			url: `${config.API_URL}/level/get.do`,
			name: "详细",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
	},
	// plog
	plog: {
		list: {
			url: `${config.API_URL}/plog/list.do`,
			name: "列表",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		save: {
			url: `${config.API_URL}/plog/save.do`,
			name: "新增/修改",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		delete: {
			url: `${config.API_URL}/plog/delete.do`,
			name: "删除",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		info: {
			url: `${config.API_URL}/plog/get.do`,
			name: "详细",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
	}, // task
	ptask: {
		list: {
			url: `${config.API_URL}/ptask/list.do`,
			name: "列表",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		save: {
			url: `${config.API_URL}/ptask/save.do`,
			name: "新增/修改",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		delete: {
			url: `${config.API_URL}/ptask/delete.do`,
			name: "删除",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		info: {
			url: `${config.API_URL}/ptask/get.do`,
			name: "详细",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
	},
	// task
	task: {
		list: {
			url: `${config.API_URL}/task/list.do`,
			name: "列表",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		save: {
			url: `${config.API_URL}/task/save.do`,
			name: "新增/修改",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		delete: {
			url: `${config.API_URL}/task/delete.do`,
			name: "删除",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		info: {
			url: `${config.API_URL}/task/get.do`,
			name: "详细",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
	}, // task
	ptemp: {
		get: {
			url: `${config.API_URL}/ptemp/get.do`,
			name: "get",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		list: {
			url: `${config.API_URL}/ptemp/list.do`,
			name: "列表",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		save: {
			url: `${config.API_URL}/ptemp/save.do`,
			name: "新增/修改",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		delete: {
			url: `${config.API_URL}/ptemp/delete.do`,
			name: "删除",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		info: {
			url: `${config.API_URL}/ptemp/get.do`,
			name: "详细",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
	},
	// 下载
	down: {
		list: {
			url: `${config.API_URL}/down/list.do`,
			name: "列表",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		save: {
			url: `${config.API_URL}/ptemp/save.do`,
			name: "新增/修改",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		delete: {
			url: `${config.API_URL}/down/delete.do`,
			name: "删除",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		info: {
			url: `${config.API_URL}/down/get.do`,
			name: "详细",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
	},
	// 告警
	alert: {
		deploy: {
			url: `${config.API_URL}/alert/deploy.do`,
			name: "布防列表",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		stat: {
			url: `${config.API_URL}/alert/stat.do`,
			name: "统计",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		list: {
			url: `${config.API_URL}/alert/list.do`,
			name: "列表",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
		image: {
			url: `${config.API_URL}/alert/image.do`,
			name: "列表",
			post: async function(data, config = {}) {
				return await http.post(this.url, data, config);
			}
		},
	},
}
